from nicegui import ui, app
# from niceguiToolkit.layout import inject_layout_tool
#
# inject_layout_tool()
# 导入
# import layoutTools

app.add_static_files(local_directory="assets", url_path="/assets")

ui.query(".nicegui-content").classes("bg-[url('/assets/login-bg.jpg')] bg-cover h-screen")


with ui.card().classes("backdrop-blur-sm bg-white/30 p-10 w-[40%] gap-4 absolute-center items-center"):
    ui.label("用户登陆").classes("text-h4")
    ui.input("用户名称")
    ui.input("密码", password=True, password_toggle_button=True)

    ui.button("登陆")


# with ui.card().classes(""):
#     ui.label("另一个卡片").classes("text-h4")

ui.run()
